package cn.com.bluemoon.daps.model.core.file.validator;

import com.alibaba.druid.DbType;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.*;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

/**
 * @author Jarod.Kong
 * @date 2021/3/15 16:09
 */
@Inherited
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD})
@Documented
@Constraint(validatedBy = MyTableTagValidator.class)
@Deprecated
public @interface MyTableTag {
    String name() default "标签";

    DbType dbType() default DbType.mysql;

    String message() default "{name}无法匹配到对应系统标签";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};

    @Target({FIELD})
    @Retention(RUNTIME)
    @Documented
    @interface List {
        MyTableTag[] value();
    }
}
